<?php

/**
 * 库存模块路由配置   
 *
 * @package    Gleez\User\Routing
 * @author     
 * @copyright  (c) 2011-2013 Gleez Technologies
 * @license    http://gleezcms.org/license Gleez CMS License
 */
if (!Route::cache()) {
    Route::set('delivery', 'inventory/(<controller>(/<action>(/<id>)))')->defaults(array(
        'controller' => 'delivery',
        'action' => 'index'
    ));

    Route::set('qcwo', 'qcwo(/<action>(/<id>))')->defaults(array(
        'controller' => 'qcwo',
        'action' => 'index'
    ));

    Route::set('stock', 'stock(/<action>(/<id>))')->defaults(array(
        'controller' => 'stock',
        'action' => 'index'
    ));
    Route::set('warehouse', 'warehouse(/<action>(/<id>))')->defaults(array(
        'controller' => 'warehouse',
        'action' => 'index'
    ));
    Route::set('balances', 'balances(/<action>(/<id>))')->defaults(array(
        'controller' => 'balances',
        'action' => 'index'
    ));

    Route::set('stockcost', 'stockcost(/<action>(/<id>))')
            ->defaults(array(
                'controller' => 'stockcost',
                'action' => 'index',
    ));

    Route::set('returnedparcel', 'returnedparcel(/<action>(/<id>))')
            ->defaults(array(
                'controller' => 'returnedparcel',
                'action' => 'index',
    ));

    Route::set('returnedparcelsort', 'returnedparcelsort(/<action>(/<id>))')
            ->defaults(array(
                'controller' => 'returnedparcelsort',
                'action' => 'index',
    ));
    Route::set('deliverytask', 'deliverytask(/<action>(/<id>))')
            ->defaults(array(
                'controller' => 'deliverytask',
                'action' => 'index',
    ));
    Route::set('mouthlykc', 'mouthlykc(/<action>(/<id>))')
            ->defaults(array(
                'controller' => 'mouthlykc',
                'action' => 'update_kc',
    ));
    Route::set('returnstock', 'returnstock(/<action>(/<id>))')
            ->defaults(array(
                'controller' => 'returnstock',
                'action' => 'index',
    ));
    Route::set('bymaterial', 'bymaterial(/<action>(/<id>))')
            ->defaults(array(
                'controller' => 'bymaterial',
                'action' => 'index',
    ));
    Route::set('checkstore', 'checkstore(/<action>(/<id>))')
            ->defaults(array(
                'controller' => 'checkstore',
                'action' => 'index',
    ));
    Route::set('createbatch', 'createbatch(/<action>(/<id>))')
            ->defaults(array(
                'controller' => 'createbatch',
                'action' => 'index',
    ));
}
/**
 * 库存模块权限配置
 *
 * Definition of user privileges by default if the ACL is present in the system.
 * Note: Parameter `restrict access` indicates that these privileges have serious
 * implications for safety.
 *
 * @uses ACL Used to define the privileges
 */
ACL::set('Stock', array(
    'administer qcwo' => array(
        'title' => __('扫描入库'),
        'restrict access' => TRUE,
        'description' => '',
    ),
    'single stock' => array(
        'title' => __('单个sku库存查询'),
        'restrict access' => TRUE,
        'description' => ''
    ),
    'stockcost' => array(
        'title' => __('库存成本查询'),
        'restrict access' => TRUE,
        'description' => '',
    ),
    'pandian' => array(
        'title' => __('盘点人员'),
        'restrict access' => TRUE,
        'description' => '',
    ),
    'delivery' => array(
        'title' => __('新建出库单+出库单批量上传'),
        'restrict access' => TRUE,
        'description' => '',
    ),
    'rate' => array(
        'title' => __('汇率的新增查询修改'),
        'restrict access' => TRUE,
        'description' => '',
    ),
    'mouth cost control' => array(
        'title' => __('开关账+期末成本更新'),
        'restrict access' => TRUE,
        'description' => '',
    ),
    'kucun detail report' => array(
        'title' => __('出入库明细报表+销售出库统计+采购入库统计'),
        'restrict access' => TRUE,
        'description' => '',
    ),
    'add warehouse' => array(
        'title' => __('手动新增入库单'),
        'restrict access' => TRUE,
        'description' => '',
    ),
    'stockcost down' => array(
        'title' => __('库存成本下载'),
        'restrict access' => TRUE,
        'description' => '',
    ),
    'create returnedparcel' => array(
        'title' => __('批次号新建+退件新建'),
        'restrict access' => TRUE,
        'description' => '',
    ),
    'update returnedparcel' => array(
        'title' => __('退件处理'),
        'restrict access' => TRUE,
        'description' => '',
    ),
    'create returnstock' => array(
        'title' => __('扫描回库'),
        'restrict access' => TRUE,
        'description' => '',
    ),
    'Bymaterial' => array(
        'title' => __('借料/备货登记'),
        'restrict access' => TRUE,
        'description' => '',
    ),
    'checkstore' => array(
        'title' => __('盘点库存(新)'),
        'restrict access' => TRUE,
        'description' => '',
    ),
));
